import request from '@/utils/request'

// 创建存储房屋的家具和物品信息
export function createHouseholdItem(data) {
  return request({
    url: '/system/household-item/create',
    method: 'post',
    data: data
  })
}

// 更新存储房屋的家具和物品信息
export function updateHouseholdItem(data) {
  return request({
    url: '/system/household-item/update',
    method: 'put',
    data: data
  })
}

// 删除存储房屋的家具和物品信息
export function deleteHouseholdItem(id) {
  return request({
    url: '/system/household-item/delete?id=' + id,
    method: 'delete'
  })
}

// 获得存储房屋的家具和物品信息
export function getHouseholdItem(id) {
  return request({
    url: '/system/household-item/get?id=' + id,
    method: 'get'
  })
}

// 获得存储房屋的家具和物品信息分页
export function getHouseholdItemPage(params) {
  return request({
    url: 'system/household-item/search',
    method: 'get',
    params
  })
}
// 导出存储房屋的家具和物品信息 Excel
export function exportHouseholdItemExcel(params) {
  return request({
    url: '/system/household-item/export-excel',
    method: 'get',
    params,
    responseType: 'blob'
  })
}
